-
Notifications
You must be signed in to change notification settings - Fork 170
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix SSL problem #269
base: master
Are you sure you want to change the base?
fix SSL problem #269
Conversation
@@ -826,7 +826,7 @@ def __init__(self, host, port=None, key_file=None, cert_file=None, | |||
http.client.HTTPSConnection.__init__( | |||
self, host, port=port, key_file=key_file, | |||
cert_file=cert_file, timeout=timeout, context=context, | |||
check_hostname=True) | |||
check_hostname=disable_ssl_certificate_validation ^ True) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change to !disable_ssl_certificate_validation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
so what if disable_ssl_certificate_validation=None
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The default is False, so that means someone would have to have intentionally passed in None, which to me falls into the realm of a personal problem, I'd much rather have readable code.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Besides which I don't think that even works:
$ python3.2
Python 3.2.3 (default, Feb 27 2014, 21:31:18)
[GCC 4.6.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
None ^ True
Traceback (most recent call last):
File "", line 1, in
TypeError: unsupported operand type(s) for ^: 'NoneType' and 'bool'
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
well, reasonable. thx
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please merge this!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@superphil0 See #173, this patch is obsolete.
As the modification of !disable_ssl_certificate_validation, I got following error when I try to install: |
You probably want |
There is also #289 , which attributes the original author. |
fix issue 173. originated by kvvier(https://code.google.com/u/kvvier/) and verified for python3.3 (win) by (https://code.google.com/u/111191101025126589579/), and me for python3.4 (linux)